package com.atguigu_e_waitandnotify;

public class Demo {
    public static void main(String[] args) {

        //创建一个包子对象,分别传递给2个线程对象
        BaoZi baoZi = new BaoZi(); //锁对象 唯一且共享

        //创建线程对象 -> 厨子线程,顾客线程
        Customer customer1 = new Customer("猪八戒",baoZi);

        Cook cook1 = new Cook("中华小当家",baoZi);


        //启动线程
        cook1.start();

        customer1.start();

    }
}
